package org.krishna.Dto;

import org.krishna.model.UserDetails;

public class BuildDTOUtils {
	
	public static User buildUserDTo(UserDetails userDetails){
		User userDTO = new User();
		userDTO.setFirstName(userDetails.getFirstName());
		userDTO.setLastName(userDetails.getLastName());
		userDTO.setMailId(userDetails.getMailId());
		userDTO.setContactNo(String.valueOf(userDetails.getContactNo()));
		userDTO.setRollNo(userDetails.getRollNo());
		userDTO.setMaxLimit(String.valueOf(userDetails.getMaxLimit()));
		userDTO.setBooksTaken(String.valueOf(userDetails.getBooksTaken()));
		return userDTO;
	}

}
